package com.mujin.keji.collectionsystem.module.tripplan.dto;

import com.baidu.mapapi.model.LatLng;
import com.mujin.keji.collectionsystem.utils.ChanLatLonUtils;

import java.io.Serializable;

/**
 * 行程规划详情dto
 *
 * @author weishixiong
 * @Time 2018-05-16
 */
public class QueryPlanDetailDto implements Serializable {
    private String addressType;// 地址类型 string @mock=$order('户籍','户籍','户籍','户籍','户籍','户籍','户籍','户籍')
    private Integer caseId;// 案件id number @mock=$order(387,386,389,393,390,388,391,392)
    private String createTime;// string @mock=$order('2018-05-11 16:56:19','2018-05-11 16:56:19','2018-05-11 16:56:19','2018-05-11 16:56:19','2018-05-11 16:56:19','2018-05-11 16:56:19','2018-05-11 16:56:19','2018-05-11 16:56:19')
    private Integer id;// number @mock=$order(1,3,4,8,5,2,6,7)
   private String location;//经纬度 ,号分割
    private String sortNum;//排序号 number @mock=$order(1,2,3,4,5,6,7,8)
    private Integer status;// 状态：0 未外访 1 已外访 number @mock=$order(0,0,0,0,0,0,0,0)
    private String visitAddress;//地址 string @mock=$order('深圳市中油大厦','深圳市汉京国际','深圳市金牛座','深圳市坪洲地铁站','深圳市海岸城西座','深圳市海王大厦','深圳市南山地铁站','深圳市后海地铁站')
    private String visitName;// 姓名 string @mock=$order('zz','张李静','zz','zz','zz','zz','zz','zz')
    private String visitRelation;//关系 string @mock=$order('本人','本人','本人','本人','本人','本人','本人','本人')
    private double lon;
    private double lat;
    private LatLng latLng;
    private String addressCity;// 市
    private String addressDistrict;// 区
    private String addressProvince;// 省
    private boolean isSelected;

    public boolean isSelected() {
        return isSelected;
    }

    public void setSelected(boolean selected) {
        isSelected = selected;
    }

    public String getAddressCity() {
        return addressCity;
    }

    public void setAddressCity(String addressCity) {
        this.addressCity = addressCity;
    }

    public String getAddressDistrict() {
        return addressDistrict;
    }

    public void setAddressDistrict(String addressDistrict) {
        this.addressDistrict = addressDistrict;
    }

    public String getAddressProvince() {
        return addressProvince;
    }

    public void setAddressProvince(String addressProvince) {
        this.addressProvince = addressProvince;
    }

    public LatLng getLatLng() {
        return ChanLatLonUtils.aliyunToBaiDu(new LatLng(getLat(), getLon()));
    }

    public void setLatLng(LatLng latLng) {
        this.latLng = latLng;
    }

    public double getLon() {
        return location == null ? 0 : Double.parseDouble(location.split(",")[0]);
    }

    public void setLon(double lon) {
        this.lon = lon;
    }

    public double getLat() {
        return location == null ? 0 : Double.parseDouble(location.split(",")[1]);
    }

    public void setLat(double lat) {
        this.lat = lat;
    }

    public String getAddressType() {
        return addressType;
    }

    public void setAddressType(String addressType) {
        this.addressType = addressType;
    }

    public Integer getCaseId() {
        return caseId;
    }

    public void setCaseId(Integer caseId) {
        this.caseId = caseId;
    }

    public String getCreateTime() {
        return createTime;
    }

    public void setCreateTime(String createTime) {
        this.createTime = createTime;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getLocation() {
        return location;
    }

    public void setLocation(String location) {
        this.location = location;
    }

    public String getSortNum() {
        return sortNum;
    }

    public void setSortNum(String sortNum) {
        this.sortNum = sortNum;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public String getVisitAddress() {
        return visitAddress;
    }

    public void setVisitAddress(String visitAddress) {
        this.visitAddress = visitAddress;
    }

    public String getVisitName() {
        return visitName;
    }

    public void setVisitName(String visitName) {
        this.visitName = visitName;
    }

    public String getVisitRelation() {
        return visitRelation;
    }

    public void setVisitRelation(String visitRelation) {
        this.visitRelation = visitRelation;
    }
}
